package com.hyjr.common.enums;

public enum CheckTypeEnum {
	SIMPLE("SIMPLE", "简单"), MIDDLE("MIDDLE", "中等"), COMPLEX("COMPLEX", "复杂");

	private String key;
	private String value;

	private CheckTypeEnum(String key, String value) {
		this.key = key;
		this.value = value;
	}

	// 根据key获取枚举
	public static CheckTypeEnum getEnumByKey(String key) {
		if (null == key) {
			return null;
		}
		for (CheckTypeEnum temp : CheckTypeEnum.values()) {
			if (temp.getKey().equals(key)) {
				return temp;
			}
		}
		return null;
	}

	public String getKey() {
		return key;
	}

	public String getValue() {
		return value;
	}
}
